#ifndef SESSIONDETAILWIDGET_H
#define SESSIONDETAILWIDGET_H

#pragma once
#include <QDialog>
#include"./model/data.h"
#include"choosefrienddialog.h"
#include<QGridLayout>
#include<QLabel>
#include<QPushButton>

/////////////////////////////
///查看详情"..."中的自定义头像
/////////////////////////////
class AvatarItem : public QWidget{
    Q_OBJECT
public:
    AvatarItem(const QIcon& avatar, const QString& name);
    void setClicked(std::function<void(void)> slotFunc);
private:
    QPushButton* avatarBtn;
    QLabel* nameLabel;
};


/////////////////////////////
///单聊显示界面
/////////////////////////////
class SessionDetailWidget : public QDialog
{
    Q_OBJECT
public:
    SessionDetailWidget(const model::ChatSessionInfo& chatSessionInfo);
private:

    //点击删除好友
    void clickDeleteFriendBtn();

    const model::ChatSessionInfo& chatSessionInfo;
};

#endif // SESSIONDETAILWIDGET_H
